DECLARE @Server NVARCHAR(30) = 'localhost', @Database NVARCHAR(50) = 'AdventureWorksDW2012Multidimensional-EE';
DECLARE @MDX NVARCHAR(MAX) = '
select [Measures].[Internet Sales Amount] on 0,
[Product].[Category].Members on 1
from [Adventure Works]
'

EXEC ExecuteOLAP @Server, @Database, @MDX;